import { ApiProperty } from '@nestjs/swagger';
import { Priority, ProjectStatus } from '../../../types/enums';
import { UserResponseDto } from '../../auth/dto/user-response.dto';

export class ProjectResponseDto {
  @ApiProperty({
    description: '项目ID',
    example: 'a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11',
  })
  id: string;

  @ApiProperty({
    description: '项目名称',
    example: '客户关系管理系统',
  })
  name: string;

  @ApiProperty({
    description: '项目描述',
    example: '一个用于管理客户关系和销售数据的系统',
  })
  description: string;

  @ApiProperty({
    description: '工作区ID',
    example: 'a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11',
  })
  workspaceId: string;

  @ApiProperty({
    description: '项目开始日期',
    example: '2023-01-01T00:00:00.000Z',
  })
  startDate: Date;

  @ApiProperty({
    description: '项目结束日期',
    example: '2023-12-31T00:00:00.000Z',
  })
  endDate: Date;

  @ApiProperty({
    description: '项目状态',
    enum: ProjectStatus,
    example: ProjectStatus.ACTIVE,
  })
  status: ProjectStatus;

  @ApiProperty({
    description: '项目优先级',
    enum: Priority,
    example: Priority.MEDIUM,
  })
  priority: Priority;

  @ApiProperty({
    description: '创建人',
    type: UserResponseDto,
  })
  createdBy: UserResponseDto;

  @ApiProperty({
    description: '创建时间',
    example: '2023-01-01T00:00:00.000Z',
  })
  createdAt: Date;

  @ApiProperty({
    description: '更新时间',
    example: '2023-01-01T00:00:00.000Z',
  })
  updatedAt: Date;
} 